package com.yanmaohu.yulia.bean;

import java.util.List;

/**
 * @author Bright Lee
 */
public final class ConstraintNameList {

    private int beginIndex;
    private int endIndex;
    private List<SchemaQualifiedName> constraintNameList;

    public ConstraintNameList(int beginIndex, int endIndex, List<SchemaQualifiedName> constraintNameList) {
        this.beginIndex = beginIndex;
        this.endIndex = endIndex;
        this.constraintNameList = constraintNameList;
    }

    public int getBeginIndex() {
        return beginIndex;
    }

    public int getEndIndex() {
        return endIndex;
    }

    public boolean isAll() {
        return constraintNameList == null || constraintNameList.isEmpty();
    }

    public int size() {
        return constraintNameList.size();
    }

    public SchemaQualifiedName get(int index) {
        return constraintNameList.get(index);
    }

}
